sgdk
|
SRAM (Static RAM used for save backup) support. More...
Go to the source code of this file.
Defines | |
#define | SRAM_CONTROL 0xA130F1 |
#define | SRAM_BASE 0x200001 |
Functions | |
void | SRAM_enable () |
Enable SRAM in Read Write mode. | |
void | SRAM_enableRO () |
Enable SRAM in Read Only mode. | |
void | SRAM_disable () |
Disable SRAM. | |
u8 | SRAM_readByte (u32 offset) |
Read a byte from the SRAM. | |
u16 | SRAM_readWord (u32 offset) |
Read a word from the SRAM. | |
u32 | SRAM_readLong (u32 offset) |
Read a long from the SRAM. | |
void | SRAM_writeByte (u32 offset, u8 val) |
Write a byte to the SRAM. | |
void | SRAM_writeWord (u32 offset, u16 val) |
Write a word to the SRAM. | |
void | SRAM_writeLong (u32 offset, u32 val) |
Write a long to the SRAM. |
SRAM (Static RAM used for save backup) support.
This unit provides methods to read from or write to SRAM.
u8 SRAM_readByte | ( | u32 | offset | ) |
Read a byte from the SRAM.
offset | Offset where we want to read. |
u32 SRAM_readLong | ( | u32 | offset | ) |
Read a long from the SRAM.
offset | Offset where we want to read. |
u16 SRAM_readWord | ( | u32 | offset | ) |
Read a word from the SRAM.
offset | Offset where we want to read. |
void SRAM_writeByte | ( | u32 | offset, |
u8 | val | ||
) |
Write a byte to the SRAM.
offset | Offset where we want to write. |
val | Value wto write. |
void SRAM_writeLong | ( | u32 | offset, |
u32 | val | ||
) |
Write a long to the SRAM.
offset | Offset where we want to write. |
val | Value wto write. |
void SRAM_writeWord | ( | u32 | offset, |
u16 | val | ||
) |
Write a word to the SRAM.
offset | Offset where we want to write. |
val | Value wto write. |